﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using Microsoft.AspNet.Identity;
using Microsoft.AspNet.Identity.Owin;
using System.Threading.Tasks;
using WebSite_Test.Models;
using LiteFramework.Contract;
using LiteFramework.Server;

namespace WebSite_Test.Account
{
    public partial class FindUser : System.Web.UI.Page
    {
        protected void UserName_Click(object sender, EventArgs e)
        {
            try
            {
                var compUser = ServerApplication.ComponentFactory.Create<IUserContract>();
                var user = compUser.GetUser(this.UserName.Text);
                this.Result.Text = string.Format("查找结果：{0} | {1} | {2}", user.ID, user.UserName, user.Identity);
            }
            catch (Exception ex)
            {
                this.Result.Text = ex.Message;
            }
            //Response.Redirect("/Account/VerifyPhoneNumber?PhoneNumber=" + HttpUtility.UrlEncode(UserName.Text));
        }
    }
}